
/** 输出：01/04 */
export const formattedDate = (str: string) => {
    const date = new Date(str);
    const formattedDate = date.toLocaleDateString('en-US', { month: '2-digit', day: '2-digit' });
    return formattedDate
}

/**  输出：2025-01-27 */
export const ObtainYearAndMonth = (str: string) => {
    const today = new Date(str);
    const formate = today.toISOString().split('T')[0];
    return formate
}
